package com.netx.generics.io;
import java.io.IOException;
import java.net.URI;
import java.net.URL;
import com.netx.generics.time.Moment;


public interface FileObject {

	public FileSystem getFileSystem();
	public String toString();
	public String getName();
	
	public int compareTo(Object o);
	public boolean equals(Object o);
	
	public String getPath();
	public String getPhysicalPath();
	
	public boolean canWrite() throws IOException;
	public boolean isHidden() throws IOException;
	public boolean isReadOnly() throws IOException;
	public void makeReadOnly() throws IOException;

	public Moment getLastModified() throws IOException;
	public void setLastModified(Moment lastModified) throws IOException;
	public long getSize() throws IOException;
	public Directory getParent() throws IOException;
	
	public boolean delete() throws IOException;
	public void deleteOnExit() throws IOException;
	
	public void renameTo(String name) throws IOException;
	public void copyTo(Directory dir) throws IOException;
	public void copyTo(Directory dir, String name) throws IOException;
	
	public URI toURI();
	public URL toURL();
}
